package com.hellobike.haxing.modules.product.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @Description: 拼团SKU
 * @Author: haxing-boot
 * @Date: 2020-01-30
 * @Version: V1.0
 */
@Data
@TableName("t_promotion_group_sku")
public class PromotionGroupSku implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(type = IdType.AUTO)
    private Long id;
    /**
     * 拼团活动id
     */
    @Excel(name = "拼团活动id", width = 15)
    private Long groupId;
    /**
     * sku id
     */
    @Excel(name = "sku id", width = 15)
    private Long skuId;
    /**
     * 拼团价
     */
    @Excel(name = "拼团价", width = 15)
    private BigDecimal groupPrice;
    /**
     * 活动库存初始量
     */
    @Excel(name = "活动库存初始量", width = 15)
    private Integer stockInit;
    /**
     * 活动库存剩余量
     */
    @Excel(name = "活动库存剩余量", width = 15)
    private Integer stockLeft;
    /**
     * 创建时间
     */
    @Excel(name = "创建时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    /**
     * 修改时间
     */
    @Excel(name = "修改时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
    /**
     * 创建人
     */
    @Excel(name = "创建人", width = 15)
    private Integer createBy;
    /**
     * 修改人
     */
    @Excel(name = "修改人", width = 15)
    private Integer updateBy;
    /**
     * 是否删除：0-否 1-是
     */
    @Excel(name = "是否删除：0-否 1-是", width = 15)
    @TableLogic
    private Integer deleted;

    /**
     * 用户限购数
     */
    @Excel(name = "用户限购数", width = 15)
    private Integer userBuyLimit;

}
